<form action="{$info['id'] == null?url('add'):url('edit')}" class="form-edit" method="post">
    <div class="row">
        <div class="col-md-6">
            <div class="form-group">
                <label class="required">机构编码</label>
                <div>
                    <input type="text" class="form-control" name="name" value="{$info.name|default=''}">
                </div>

            </div>
        </div>

        <div class="col-md-6">
            <div class="form-group">
                <label class="required">机构名称</label>
                <div>
                    <input type="text" class="form-control" name="title" value="{$info.title|default=''}">
                </div>

            </div>
        </div>
        <div class="col-md-6">
            <div class="form-group">
                <label class="required">上级机构</label>
                <div>
                    {html:select name="pid" options="office_parent" selected="info['pid']" clazz="form-control"
                    first="顶级部门"/}
                </div>
            </div>
        </div>
        <div class="col-md-6">
            <div class="form-group">
                <label class="required">机构类型</label>
                <div>
                    {html:select name="type" options="office_type" selected="info['type']" clazz="form-control"/}
                </div>
            </div>
        </div>
        <div class="col-md-6">
            <div class="form-group">
                <label class="required">排序</label>
                <div>
                    <input type="text" class="form-control" name="sort" value="{$info.sort|default=''}">
                </div>

            </div>
        </div>
        <div class="col-md-6">
            <div class="form-group">
                <label>备注说明</label>
                <div>
                    <input type="text" class="form-control" name="remark" value="{$info.remark|default=''}">
                </div>
            </div>

        </div>

    </div>
    <hr style="margin-top: 0; margin-bottom: 15px; margin-left: -15px; margin-right: -15px;"/>
    <div class="text-right">
        <input type="hidden" name="id" value="{$info.id|default=''}">
        <button type="button" class="btn btn-default" data-dismiss="modal">
            <i class="icon icon-times"></i> 关闭
        </button>
        <button class="btn btn-primary ajax-post" type="submit" data-href="form-edit">
            <i class="icon icon-save"></i> 保存
        </button>
    </div>
</form>

